package com.neuedu.config;

import com.alibaba.cloud.nacos.annotation.NacosConfig;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author 金山
 * 项目：sca-all-in-one
 * site: https://blog.fulfill.com.cn
 * 描述
 * @data 2025/6/311:01
 */

@RestController
public class DBController {


    @NacosConfig(dataId = "config.yaml", group = "DEFAULT_GROUP", key = "db.username")
    private String username;


    @NacosConfig(dataId = "config.yaml", group = "DEFAULT_GROUP", key = "db.password")
    private String password;


    @RequestMapping("/dbinfo")
    public String dbinfo() {

        return String.format("username:%s , password: %s", username, password);
    }


}
